package com.easylinkin.linkappapi.grid.models.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * @author kyj
 * @date 2024/5/23 10:31
 */
@ApiModel(description = "")
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class GridFileSaveDTO implements Serializable {

    public @interface Save {
    }

    /**
     * 业务id
     */
    @ApiModelProperty(value = "业务id", position = 1, required = true)
    @NotNull(message = "业务ID不能为空", groups = {Save.class})
    private String busId;

    /**
     * 1:日报 2:周报
     *
     * @see com.easylinkin.linkappapi.grid.enums.EGridFileBusType
     */
    @ApiModelProperty(value = "1:日报 2:周报", position = 2, required = true)
    @NotNull(message = "业务类型不能为空")
    private Integer busType;

    /**
     * 业务子类型
     *
     * @see com.easylinkin.linkappapi.grid.enums.IGridFileBusSubType
     */
    @ApiModelProperty(value = "业务子类型", position = 3, required = true)
    @NotNull(message = "业务子类型不能为空")
    private Integer busSubType;

    /**
     * 业务子内容（自定义）
     */
    @ApiModelProperty(value = "业务子内容（自定义）", position = 4)
    private String busSubContent;

    /**
     * 文件url
     */
    @ApiModelProperty(value = "文件url", position = 4, required = true)
    @NotEmpty(message = "文件url不能为空")
    private String fileUrl;

    /**
     * 文件名称
     */
    @ApiModelProperty(value = "文件名称", position = 5)
    private String fileName;
}
